package com.probox.common.core.enums;

/**
 * 客户等级权益
 * @author liuhj
 */
public enum CustomerLevelPrivilegeEnum {


    freeShipping("freeShipping","包邮"),
    discount("discount","打折"),
    points("points","送积分"),
    coupon("coupon","送优惠券"),
    gift("gift","送赠品"),
    card("card","好友体验卡"),
    proboxCard("proboxCard","套餐卡"),
    item("item","服务项目"),
    good("good","家具商品"),
    multiplePoints("multiplePoints","积分倍率");


    private CustomerLevelPrivilegeEnum(String k, String v) {
        this.setKey(k);
        this.setValue(v);
    }

    public static String getNameByKey(String key) {
        String rst = "";
        for(CustomerLevelPrivilegeEnum oe: CustomerLevelPrivilegeEnum.values()) {
            if (oe.getKey().equals(key)) {
                rst = oe.getValue();
            }
        }
        return rst;
    }

    private String key;
    private String value;

    public String getKey() {
        return key;
    }
    public void setKey(String key) {
        this.key = key;
    }
    public String getValue() {
        return value;
    }
    public void setValue(String value) {
        this.value = value;
    }
}
